<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateTcmFoodDetailTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('tcm_food_detail', function (Blueprint $table) {
            $table->increments('id');
			$table->integer('mid')->index()->default('0')->nullable()->comment('分类ID');
            $table->string('name')->nullable()->comment('名称');
            $table->string('shareImg')->nullable()->comment('分享图');
            $table->string('picture')->nullable()->comment('图片');
            $table->text('meridian')->nullable()->comment('归经');
            $table->text('taste')->nullable()->comment('味');
            $table->text('application')->nullable()->comment('用途');
            $table->text('composition')->nullable()->comment('成分');
            $table->string('classification')->nullable()->comment('分类');
            $table->string('natures')->nullable()->comment('性质');
            $table->string('effects')->nullable()->comment('功能');
            $table->string('flavors')->nullable()->comment('味');
            $table->string('concretEffects')->nullable()->comment('详细功能');
            $table->text('contraindication')->nullable()->comment('禁忌');
            $table->timestamps();
            $table->softDeletes();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('tcm_food_detail');
    }
}
